#ifndef ENDINGPANEL_H
#define ENDINGPANEL_H

#include "scorepanel.h"
#include <QLabel>
#include <QPushButton>
#include <QWidget>

class EndingPanel : public QWidget
{
    Q_OBJECT
public:
    explicit EndingPanel(bool isLord, bool isWin , QWidget *parent = nullptr);

    // 设置玩家的分数
    void setPlayerScore(int left, int right, int me);
    // 设置玩家的用户名
    void setPlayerName(QByteArrayList names);

signals:
    void continueGame(); // 通知主界面继续游戏的信号

protected:
    void paintEvent(QPaintEvent* ev);

private:
    QPixmap m_bk;
    QLabel* m_title;
    ScorePanel* m_scorePanel;
    QPushButton* m_continue;
};

#endif // ENDINGPANEL_H
